{extend name="template/base" /}
{block name="style"}
<style>
    @media screen and (min-width:800px){
        .list-wrapper{
            display: flex;
            flex-wrap: wrap;
        }
        .list-group{
            width: 33%;
            margin-right: 5px;
        }
    }
</style>
{/block}
{block name="content"}

<!--下拉菜单-->
<div class="dropdown">
    <button type="button" class="btn dropdown-toggle" id="dropdownMenu1" data-toggle="dropdown">{$city}
        <span class="caret"></span>
    </button>
    <ul style="height:1000px;overflow:scroll" class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu1">
        {volist name="citylist" id="vo"}
        <li role="presentation">
            <a role="menuitem" tabindex="-1" href="?city={$vo}">{$vo}</a>
        </li>
        {/volist}
    </ul>
</div>

<!--招聘内容-->
<div class="list-wrapper">
    {volist name="list" id="vo"}
        <div class="list-group">
            <a target="_blank" href="https://www.lagou.com/jobs/{$vo.positionId}.html?source=home_hot&i=home_hot-0" class="list-group-item active">
                <h4 class="list-group-item-heading">
                    {$vo.companyFullName}（{$vo.companyName}）
                </h4>
            </a>
            <a target="_blank" href="https://www.lagou.com/jobs/{$vo.positionId}.html?source=home_hot&i=home_hot-0" class="list-group-item">
                <h4 class="list-group-item-heading">
                    {$vo.positionName}
                </h4>
                <p class="list-group-item-text">
                    工作地址 ： {$vo.city}
                </p>
            </a>
            <a target="_blank" href="https://www.lagou.com/jobs/{$vo.positionId}.html?source=home_hot&i=home_hot-0" class="list-group-item">
                <h4 class="list-group-item-heading">
                    招聘金额：{$vo.salary}
                </h4>
                <p class="list-group-item-text">
                    时间： {$vo.createTime}
                </p>
            </a>
        </div>
    {/volist}
</div>

<!--分页-->
<ul class="pager">
    <li><a href="?city=<?php echo $city; ?>&page=<?php echo $page - 1; ?>">&laquo;</a></li>
        <?php  for ($i = $page; $i < $totalPages; $i++){ ?>
        <?php if ($i < ($page + 5)){ ?>
        <li class="active"><a href="?page=<?php echo $i; ?>"><?php echo $i;?></a></li>
        <?php } ?>
        <?php } ?>
    <li><a href="?city=<?php echo $city; ?>&page=<?php echo $page + 1; ?>">&raquo;</a></li>
</ul>

<!--上拉翻页-->




{/block}
{block name="script"}{/block}